package gamehistory.utils.computation;

/**
 * A simple constants class consisting of commonly referenced polynomials in the current problem space.
 * @author Team Nerdicide - Brent Kersanske and Brad Lajoie
 * @since 9/30/2009
 * @version Last modified 10/1/2009
 */
public class CommonPolynomials {

	/* Basic building block polynomials */
	public static final Polynomial one                     = new Polynomial(1, 0);
	public static final Polynomial p                       = new Polynomial(1, 1);
	public static final Polynomial oneMinusP               = one.subtract(p);
	public static final Polynomial powerTwo                = new Polynomial(1, 2);
	public static final Polynomial powerThree              = new Polynomial(1, 3);
	
	/* Polynomials representing probabilities of events. */
	public static final Polynomial oneMinusPPowerThree     = powerThree.compose(oneMinusP);
	public static final Polynomial oneMinusPPowerTwoTimesP = powerTwo.compose(oneMinusP).multiply(p); 
	public static final Polynomial oneMinusPTimesPPowerTwo = oneMinusP.multiply(powerTwo.compose(p));
	public static final Polynomial pPowerThree             = powerThree.compose(p);
	
}
